package swf;

class SI32 {
	public static function fromInt ( n : Int ) : String {
		var val = 	String.fromCharCode( n & 0xff );
		val += 		String.fromCharCode( (n >> 8) & 0xff );
		val +=		String.fromCharCode( (n >> 16) & 0xff );
		val +=		String.fromCharCode( ((n<0) ? (1<<7) : 0) | ((n >> 24) & 0x3f) );
		
		return val;
	}
}
